#include <stdio.h>

char *mystrchr(const char *p, int c);
int main(int argc, char *argv[])
{
	char *ptr;
	// argv[1] --->string argv[2]--->charactor
	if (argc < 3)
		return 1;
	ptr = mystrchr(argv[1], *argv[2]);
	if (NULL == ptr) {
		printf("not found\n");
	} else {
		printf("find it:%s\n", ptr);
	}

	return 0;
}

char *mystrchr(const char *p, int c)
{
	while (*p) {
		if (c == *p)
			return (char *)p;
		p++;
	}
	return NULL;
}






